Numbers spoken in parts

People rarely say a long number in one go, and the STT engine writes down each part they say as a number of its own:

The Large Language Model then has to guess which parts make up one number, and may read back or pass to a tool a number the user never said. The numbers_sequence parameter reformats such a sequence into one number before the utterance reaches the model: "I need bus 529", "my phone is 61333528".

Enable it by adding the numbers_sequence parameter to the Advanced tab of the Agent's or Flow's dialog:

{
    "numbers_sequence": {
        "mode": "auto",
        "prefixes": ["bus", "phone is"]
    }
}

This applies to Agents and Flows on regular (non-speech-to-speech) models. It reformats typed utterances too, so you can try it in Chat by typing an utterance the way the STT engine would write it.

Parameter Type Description
numbers_sequence NumbersSequence Reformat numbers spoken in parts into one number.

NumbersSequence

Parameter Type Description
mode enum Supported values:
• auto – add up a number the STT engine split where the user paused, and join the rest: "500 29" → "529" (recommended)
• join – join the parts: "5 2 9" → "529"
Without a mode, numbers are left as they are.
prefixes list[str] Words that come before the numbers to reformat, matched regardless of case. ^ matches the start of the utterance.
Default – every sequence of numbers in the utterance is reformatted.

Choosing a mode

auto is the recommended mode: besides joining the parts, it covers for the STT engine splitting a number where the user paused in the middle of it – "500", a pause, "29", when the user meant "529". If your STT engine never produces such splits, join is enough.

Numbers separated by commas are joined as well – "6, 1, 3" becomes "613". A number followed by ., ! or ? ends the sequence, and the punctuation is kept.

Limiting it to the numbers you expect

Without prefixes, every sequence of numbers in the utterance is reformatted, including numbers that only happen to follow each other – "bus 500 29 at 7 30" would become "bus 529 at 730". List the words that come before the numbers you expect, and only a sequence right after one of them is reformatted: with the bus prefix the same utterance becomes "bus 529 at 7 30".

When the pause ends the utterance

A long enough pause makes the STT engine end the utterance, so the parts of the number reach the agent as two utterances – "my ID number is 1 2 3", then "4 5 6" – and numbers_sequence sees each one on its own. Incomplete turn detection and Continued utterances join such utterances into one before numbers_sequence runs, so the number is reformatted whole.

Monitoring

The conversation log keeps the utterance as the STT engine wrote it. When numbers_sequence changes it, the log also shows a USER INPUT AFTER CORRECTION entry with the text the model received.